home *** CD-ROM | disk | FTP | other *** search
/ Die Ultimative Software-P…i Collection 1996 & 1997 / Die Ultimative Software-Pakete CD-ROM fur Atari Collection 1996 & 1997.iso / p / pov / povlisti.ngs / flyrod1.pov < prev    next >
Encoding:
Text File  |  1992-05-17  |  13.1 KB  |  377 lines

  1. // Persistence of Vision Raytracer
  2. // Flyrod & flyreel by Dan Farmer  May '92
  3. // 5 hours 17 min on 33/486 +a0.1 640x480
  4. #include "include.inc"
  5. #declare Bamboo1 = colour  red   1.00 green   0.78 blue   0.46
  6. #declare Bamboo2 = colour  red   0.97 green   0.82 blue   0.47
  7.  
  8. #declare Reel_Texture = texture {
  9.     0.1
  10.     Shiny
  11.     color Gray50
  12. }
  13.  
  14. #declare Nickle_Silver = texture {
  15.     0.25
  16.     Metal
  17.     color red 0.94 green 0.93 blue 0.83
  18. }
  19.  
  20.  
  21. #declare Cork = texture {
  22.     0.05
  23.     granite
  24.     colour_map {
  25.         [0.0 0.6  colour red 0.93 green 0.71 blue 0.532
  26.                   colour red 0.98 green 0.81 blue 0.60]
  27.         [0.6 0.65 colour red 0.50 green 0.30 blue 0.20
  28.                   colour red 0.50 green 0.30 blue 0.20]
  29.         [0.65 1.0 colour red 0.80 green 0.53 blue 0.46
  30.                   colour red 0.85 green 0.75 blue 0.35]
  31.     }
  32.     scale <0.25 0.25 0.25>     // Generally looks best scaled longer on one axis
  33.     specular 0.1 roughness 0.5 // Very dull
  34.     ambient 0.1
  35.     diffuse 0.5
  36. }
  37.  
  38. #declare RoseWood = texture {
  39.     DMFWood3
  40.     rotate <0 875 0>              // For x cylinder on reelseat (almost 90)
  41.     ambient 0.3
  42.     specular 0.85 roughness 0.005
  43. }
  44.  
  45. // Torus, Outer 2.23, inner 2.075.
  46. // Used as beaded rim on flyreel frame
  47. #declare Split_Torus =
  48.     intersection {
  49.         quartic {
  50.            <    1.000000 0.000000 0.000000 0.000000 2.000000
  51.                 0.000000 0.000000 2.000000 0.000000 -9.368125
  52.                 0.000000 0.000000 0.000000 0.000000 0.000000
  53.                 0.000000 0.000000 0.000000 0.000000 0.000000
  54.                 1.000000 0.000000 0.000000 2.000000 0.000000
  55.                 9.337500 0.000000 0.000000 0.000000 0.000000
  56.                 1.000000 0.000000 -9.368125 0.000000 21.797227
  57.             >
  58.         }
  59.     plane {<0 1 0> 0}
  60.     rotate <90 0 0>
  61. }
  62.  
  63.  
  64.  
  65. /*
  66. // Over-all view of reel and butt section of rod
  67. camera {
  68.    location <-5.0  2  -50>
  69.    direction <0.0 0.0  3.0>
  70.    up  <0.0  1.0  0.0>
  71.    right <1.33333 0.0 0.0>
  72.    look_at <0 -2 0>
  73. }
  74. */
  75.  
  76. // Closeup view of the reel set and reel
  77. camera {
  78.    location <-14.0  2  -20>
  79.    direction <0.0 0.0  3.0>
  80.    up  <0.0  1.0  0.0>
  81.    right <1.33333 0.0 0.0>
  82.    look_at <-6 -2 0>
  83. }
  84.  
  85. object { light_source  { <-2  30 -20>  color White  } }
  86. object { light_source  { < -20 5 -5>  color Gray75  } }
  87. object { sphere {<0 0 0> 10000 } texture {0.035 color DimGray ambient 1 diffuse 0} }
  88.  
  89.  
  90. #declare FlyRod = composite {
  91.  
  92.     // Cork flyrod handle
  93.     object {
  94.         union {
  95.             intersection { X_Disk }
  96.             quadric { Ellipsoid translate <1 0 0> }
  97.         }
  98.         color Red
  99.         texture { Cork scale <2 1 1> }
  100.         scale <5 1 1>
  101.     }
  102.  
  103.     // Reelseat
  104.     object {
  105.         intersection { X_Disk scale <2 0.75 0.75> translate <-7 0 0> }
  106.         color Orange
  107.         texture { RoseWood
  108.             DMFWood3
  109.             rotate <0 90 0>
  110.             ambient 0.25
  111.             specular 0.85 roughness 0.005
  112.         }
  113.     }
  114.  
  115.     // Metal Cap and band for end of reelseat
  116.     object {
  117.         union {
  118.             intersection { X_Disk scale <0.5 0.78 0.76> translate <-9.5 0 0> } // Cap
  119.             intersection { X_Disk scale <0.05 0.82 0.82> translate <-9.05 0 0> }
  120.             quadric { Ellipsoid   scale <0.20 0.80 0.80> translate <-10 0 0> }
  121.  
  122.             intersection { X_Disk scale <0.05 0.82 0.82> translate <-6.7 0 0> } // Band
  123.             intersection { X_Disk scale <0.25 0.78 0.76> translate <-6.5 0 0> } // Band
  124.             intersection { X_Disk scale <0.05 0.82 0.82> translate <-6.3 0 0> } // Band
  125.         }
  126.         color Yellow
  127.         texture {
  128.             Nickle_Silver
  129.         }
  130.     }
  131.  
  132.  
  133.     object {
  134.         // Bamboo flyrod (sorry, it's not tapered)
  135.         intersection { Hexagon
  136.             rotate <30 0 0>
  137.         }
  138.         color Green
  139.         texture {
  140.             Glossy
  141.             gradient <1 0 0>
  142.             color_map {
  143.                 [0.0 0.02 color green 0.35 color green 0.35]
  144.                 [0.02 0.03 color Yellow color Yellow]
  145.                 [0.03 0.07 color green 0.35 color green 0.35]
  146.                 [0.07 0.08 color Yellow color Yellow]
  147.                 [0.08 0.1 color green 0.35 color green 0.35]
  148.                 [0.1 1.0 color Bamboo1 color Bamboo2]
  149.             }
  150.             scale <0.1 1 1>
  151.             translate <-1 0 0>
  152.         }
  153.  
  154.  
  155. /* ----------
  156.         // Graphite flyrod (tapered)
  157.         union {
  158.             intersection { HalfCone_Y
  159.                 rotate <0 0 -90>
  160.             }
  161.         }
  162.         color Green
  163.         texture {
  164.             Glossy
  165.             gradient <1 0 0>
  166.             color_map {
  167.                 [0.0 0.02 color Red color Red]
  168.                 [0.02 0.03 color Black color Black]
  169.                 [0.03 0.07 color Red color Red]
  170.                 [0.07 0.08 color Black color Black]
  171.                 [0.08 0.1 color Red color Red]
  172.                 [0.1 1.0 color Gray50 color Gray50]
  173.             }
  174.             scale <0.1 1 1>
  175.             translate <-1 0 0>
  176.         }
  177. ----------------*/
  178.         scale <100 0.25 0.25>
  179.         translate <110 0 0>
  180.     }
  181.  
  182. }    // end of flyrod composite
  183.  
  184.  
  185. #declare Reel = composite {
  186.  
  187.  
  188.  
  189.     // Inner spool w/line on it
  190.     // This is simply a Z_Disk with separate textures on each part.
  191.     // The gradients are to simulate the flyline
  192.     object {
  193.         intersection {
  194.             quadric { Cylinder_Z
  195.                 texture {
  196.                     gradient <0 0 1>
  197.                     color_map {
  198.                         [0.0  0.25 color DimGray color White]
  199.                         [0.25 0.75 color White color White]
  200.                         [0.75  1.0 color White  color DimGray  ]
  201.                     }
  202.                     scale <1 1 0.1 >
  203.                     ambient 0.3
  204.                 }
  205.             }
  206.             plane { <0 0 1> -1 inverse
  207.                 texture {
  208.                     wood
  209.                     turbulence 0
  210.                     color_map {
  211.                         [0.0  0.25 color DimGray color White]
  212.                         [0.25 0.75 color White color White]
  213.                         [0.75  1.0 color White  color DimGray  ]
  214.                     }
  215.                     scale <0.1 0.1 1 >
  216.                     ambient 0.3
  217.                 }
  218.             }
  219.  
  220.             plane { <0 0 1>  1
  221.                 texture {
  222.                     wood
  223.                     turbulence 0
  224.                     color_map {
  225.                         [0.0  0.25 color DimGray color White]
  226.                         [0.25 0.75 color White color White]
  227.                         [0.75  1.0 color White  color DimGray  ]
  228.                     }
  229.                     scale <0.1 0.1 1 >
  230.                     ambient 0.3
  231.                 }
  232.             }
  233.         }
  234.         color Blue
  235.         scale <1.65 1.65 1>
  236.     }
  237.  
  238.     // Flanges
  239.     object {
  240.         difference {
  241.             difference {
  242.                 union {
  243.                     intersection { Z_Disk scale <2 2 0.15> translate <0 0 -1> }
  244.                     intersection { Z_Disk scale <2 2 0.15> translate <0 0  1> }
  245.                 }
  246.                 union {
  247.                     intersection { Z_Disk scale <1.95 1.95 0.075> translate <0 0 -1.15> }
  248.                     intersection { Z_Disk scale <1.95 1.95 0.075> translate <0 0  1.15> }
  249.                 }
  250.             }
  251.             union {
  252.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> }
  253.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0  22.5>}
  254.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0  45>}
  255.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0  67.5>}
  256.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0  90>}
  257.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 112.5>}
  258.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 135>}
  259.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 157.5>}
  260.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 180>}
  261.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 202.5>}
  262.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 225>}
  263.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 247.5>}
  264.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 270>}
  265.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 292.5>}
  266.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 315>}
  267.                 quadric { Cylinder_Z scale <0.2 0.2 1> translate <0 1.5 0> rotate <0 0 337.5>}
  268.  
  269.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> }
  270.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0  22.5>}
  271.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0  45>}
  272.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0  67.5>}
  273.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0  90>}
  274.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 112.5>}
  275.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 135>}
  276.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 157.5>}
  277.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 180>}
  278.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 202.5>}
  279.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 225>}
  280.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 247.5>}
  281.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 270>}
  282.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 292.5>}
  283.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 315>}
  284.                 quadric { Cylinder_Z scale <0.125 0.125 1> translate <0 1 0> rotate <0 0 337.5>}
  285.             }
  286.         }
  287.         bounded_by { intersection { Z_Disk scale <2.1 2.1 1.2> } }
  288.         color Cyan
  289.         texture { Reel_Texture }
  290.     }
  291.  
  292.     // Handle
  293.     object {
  294.         union {
  295.             intersection { Z_Disk scale <0.2 0.2 0.5>
  296.                 translate <0 1.5 -1.5>
  297.                 rotate <0 0 22.5>
  298.             }
  299.             // Button on the end of the handle
  300.             quadric { Ellipsoid  scale <0.15 0.15 0.025>
  301.                 translate <0 1.5 -2>
  302.                 rotate <0 0 22.5>
  303.                 texture { Nickle_Silver }
  304.             }
  305.         }
  306.         color Magenta
  307.         texture { Shiny color Black }
  308.     } // end of handle
  309.  
  310.  
  311.     // Hub cap
  312.     object {
  313.         union {
  314.             intersection { Z_Disk scale <0.35 0.35 0.1>  }
  315.             quadric { Ellipsoid scale <0.25 0.25 0.15> }
  316.         }
  317.         translate <0 0 -1.1>
  318.         texture { Nickle_Silver }
  319.     } // end of hub cap
  320.  
  321.  
  322.     // Reel Frame
  323.     object {
  324.         union {
  325.             difference {
  326.                 union {
  327.                     intersection { Z_Disk scale <2.25 2.25 0.15> translate <0 0 -1> }
  328.                     intersection { Z_Disk scale <2.25 2.25 0.15> translate <0 0  1> }
  329.                 }
  330.                 union {
  331.                     quadric { Cylinder_Z scale <2.075 2.075 1> }
  332.                     quadric { Cylinder_Z scale <2.075 2.075 1> }
  333.                 }
  334.             }
  335.             // Crossbars
  336.             box { UnitBox scale <0.075 0.075 0.85> translate <0 2.175 0> rotate <0 0 90>}
  337.             box { UnitBox scale <0.075 0.075 0.85> translate <0 2.175 0> rotate <0 0 180>}
  338.             box { UnitBox scale <0.075 0.075 0.85> translate <0 2.175 0> rotate <0 0 -90>}
  339.             // Beaded rim
  340.             intersection { Split_Torus translate <0 0 -1.15>}
  341.             intersection { Split_Torus rotate <180 0 0> translate <0 0 +1.15>}
  342.         }
  343.         color Red
  344.         texture { Reel_Texture }
  345.         bounded_by { intersection { Z_Disk scale <2.4 2.4 1.21> } }
  346.     } // end of reel frame
  347.  
  348.  
  349.     // Reel Foot
  350.     object {
  351.         union {
  352.             intersection {
  353.                 difference {
  354.                     intersection {X_Disk scale <1.75 0.77 0.77> }
  355.                     intersection {X_Disk scale <1.85 0.75 0.75> }
  356.                 }
  357.                 plane { <0 1 0> -0.40 }
  358.                 quadric { Cylinder_Y scale <1.75 0.75 1>}
  359.             }
  360.             box { UnitBox scale <0.5 0.075 0.50> translate <0 -0.825 0> }
  361.             box { UnitBox scale <0.25 0.075 0.85> translate <0 -0.975 0> color Green }
  362.         }
  363.         color Orange
  364.         texture { Reel_Texture }
  365.         bounded_by {
  366.             box { UnitBox scale <1.85 1 0.85> }
  367.         }
  368.         translate <0 2.77 0>
  369.     }  // end of reel foot
  370.  
  371. }
  372.  
  373. composite {
  374.     composite {Reel translate <-8 -2.75  0> }
  375.     composite {FlyRod}
  376. }
  377.